import { Component, OnInit } from '@angular/core';
import { HomeService } from '../home.service';
import { item } from  "../mock";

@Component({
  selector: 'app-home',
  templateUrl: './home.component.html',
  styleUrls: ['./home.component.sass']
})
export class HomeComponent implements OnInit {
  list: item []
  constructor(
    private homeService: HomeService
  ) {  }


  ngOnInit() {
    this.homeService.getHomeList().subscribe(res => {
      this.list = res;
    })
  }

}
